(function($){ $('.card').flip({ trigger: 'hover', }) $("[data-img-src]").each(function(index, item){ var imgSrc=$(item).data("imgSrc"); $(item).css({ "background-image": "url("+imgSrc+")", "background-size": "cover" }); }); $('.tour-sidebar').on('click', function(){ var ttl=$(this); ttl.toggleClass('accordion__ttl--open'); ttl.next('.accordion__content').slideToggle(); }).first().click(); $('.filter-sidebar').on('click', function(){ var ttl=$(this); ttl.toggleClass('accordion__ttl--open'); ttl.next('.accordion__content').slideToggle(); }); $('.destination__mv__desc').each(function(){ var btn=$(this); btn.on('click', function(){ var status=$('.destination__mv__desc').attr("status"); if(status=="close"){ btn.toggleClass('destination__mv__desc--open'); $('.destination__mv__txt p').fadeIn(); $('.destination__mv__desc').attr("status", "open"); }else{ btn.removeClass('destination__mv__desc--open'); $('.destination__mv__txt p:nth-child(2), .destination__mv__txt p:nth-child(3)').fadeOut(); $('.destination__mv__desc').attr("status", "close"); }}); }); var swiper=new Swiper('.about__team__list', { slidesPerView: 4, slidesPerGroup: 4, loop: true, breakpoints: { 750: { slidesPerView: 1, slidesPerGroup: 1, }}, pagination: { el: '.about__team__pagination', clickable: true, }, }); var swiper=new Swiper('.blog__categories__list', { slidesPerView: 6, slidesPerGroup: 1, breakpoints: { 750: { slidesPerView: 3, slidesPerGroup: 1, }}, navigation: { nextEl: '.blog__categories__next', prevEl: '.blog__categories__prev', }, }); var swiperOpts={ slidesPerView: 'auto', breakpoints: { 750: { slidesPerView: 1, }}, }; var swiper_postList=new Swiper('.home__lastest__list__ins, .blogDetail__sidebar__cat__list', swiperOpts); var best_of_slider=undefined; function initSwiper(){ var screenWidth=$(window).width(); if(screenWidth < 750&&best_of_slider==undefined){ best_of_slider=new Swiper('.destination__tour__list__best', { }); }else if(screenWidth > 750&&best_of_slider!=undefined){ best_of_slider.destroy(); best_of_slider=undefined; jQuery('.swiper-wrapper').removeAttr('style'); jQuery('.swiper-slide').removeAttr('style'); }} initSwiper(); $(window).on('resize', function(){ initSwiper(); }); var swiper=new Swiper('.review__homepage', { slidesPerColumn: 1, slidesPerGroup: 2, navigation: { nextEl: '.review-homepage__next', prevEl: '.review-homepage__prev', clickable: true, }, }); var swiper=new Swiper('.review__list', { slidesPerColumn: 2, navigation: { nextEl: '.review__next', prevEl: '.review__prev', clickable: true, }, }); var swiper=new Swiper('.tripadvisor__list', { spaceBetween: 1, navigation: { nextEl: '.tripadvisor__next', prevEl: '.tripadvisor__prev', clickable: true, }, }); var swiper=new Swiper('.about__gallery__list', { slidesPerView: 1, loop: true, pagination: { el: '.swiper-pagination', clickable: true, }, }); var swiperHome=new Swiper('.home__mv__list', { spaceBetween: 0, slidesPerView: 1, loop: true, pagination: { el: '.swiper-pagination', clickable: true, }, breakpoints: { 750: { slidesPerView: 1, }, }}); var swiperFlit=new Swiper('.home__intro__itemAera', { effect: 'flip', grabCursor: true, autoplay: { }, breakpoints: { 750: { autoplay:false, }, }}); if($(".home__intro__itemAera").length){ $.each(swiperFlit, function(i, item){ item.params.autoplay.delay=5000 + i * 1000; item.update(); }) } if($("[data-selectmenu]").length){ $("[data-selectmenu]").selectmenu({ 'classes': { 'ui-selectmenu-button': 'customized__input__select-btn', 'ui-selectmenu-icon': 'customized__input__select-icon', 'ui-selectmenu-text': 'customized__input__select-text', 'ui-selectmenu-menu': 'customized__input__select-menu' }, 'open': function(e, ui){ var $target=$(e.target); var $menu=$target.closest(".customized__group__wrapper").find(".customized__input__select-menu"); $menu.css({'top': '100%'}); }}); } if($("[data-img-src]").length){ $("[data-img-src]").each(function(i, item){ var imgSrc=$(item).data('imgSrc'); $(item).css({ 'background-image': 'url(' + imgSrc + ')' }); }); } $('a[href^="#"]:not([href$="#"])').on("click", function(e){ $(".customized__nav__anchor").removeClass('customized__nav__anchor--active'); $(e.target).addClass('customized__nav__anchor--active'); }); AOS.init({ }); $(".contact__input__input--gender").find("option").eq(0).remove(); var count=$("#menu-item-35 ul li ul li").length; var minHeight=count * 10; $("#menu-item-35 ul").css({"min-height": minHeight + "vw"}); $("#menu-item-35 ul li ul").css({"min-height": minHeight + "vw"}); if($("[selectmenu]").length){ $("[selectmenu]").selectmenu({ 'classes': { 'ui-selectmenu-button': 'tourstyle__filter__box-btn', 'ui-selectmenu-icon': 'tourstyle__filter__box-icon', 'ui-selectmenu-text': 'tourstyle__filter__box-text', 'ui-selectmenu-menu': 'tourstyle__filter__box-menu', }, 'open': function(e, ui){ var $target=$(e.target); var $icon=$target.closest(".ui-front").find(".tourstyle__filter__box-icon"); $icon.addClass("tourstyle__filter__box-icon--open"); }, 'close': function(e, ui){ var $target=$(e.target); var $icon=$target.closest(".ui-front").find(".tourstyle__filter__box-icon"); $icon.removeClass("tourstyle__filter__box-icon--open"); }}); } if($("[selectmenu2]").length){ $("[selectmenu2]").selectmenu({ 'classes': { 'ui-selectmenu-button': 'blogCat__search__box-btn', 'ui-selectmenu-icon': 'blogCat__search__box-icon', 'ui-selectmenu-text': 'blogCat__search__box-text', 'ui-selectmenu-menu': 'blogCat__search__box-menu', }, 'open': function(e, ui){ var $target=$(e.target); var $icon=$target.closest(".ui-front").find(".blogCat__search__box-icon"); $icon.addClass("blogCat__search__box-icon--open"); }, 'close': function(e, ui){ var $target=$(e.target); var $icon=$target.closest(".ui-front").find(".blogCat__search__box-icon"); $icon.removeClass("blogCat__search__box-icon--open"); }}); } $('#tabs').responsiveTabs({ startCollapsed: 'accordion' }); $('.detailTour__content__drop__item__expand').each(function(){ $(this).on('click', function(){ $('.accordion__content__ttl').addClass('accordion__content__ttl--open'); $('.accordion__content__txt').slideDown(); }); }); $('.detailTour__content__drop__item__collapse').each(function(){ $(this).on('click', function(){ $('.accordion__content__ttl').removeClass('accordion__content__ttl--open'); $('.accordion__content__txt').slideUp(); }); }); $('.accordion__content__ttl').each(function(){ var ttl=$(this); ttl.on('click', function(){ ttl.toggleClass('accordion__content__ttl--open'); ttl.next('.accordion__content__txt').slideToggle(); }); }); $('.faqs__content__drop__item__expand').on('click',function(){ if($('.accordion__faqs__content__ttl').hasClass('accordion__faqs__content__ttl--open')==false){ $('.accordion__faqs__content__ttl').addClass('accordion__faqs__content__ttl--open'); $('.accordion__faqs__content__ttl').next('.accordion__faqs__content__txt').slideToggle(); }}); $('.faqs__content__drop__item__collapse').on('click',function(){ if($('.accordion__faqs__content__ttl').hasClass('accordion__faqs__content__ttl--open')==true){ $('.accordion__faqs__content__ttl').removeClass('accordion__faqs__content__ttl--open'); $('.accordion__faqs__content__ttl').next('.accordion__faqs__content__txt').fadeOut(); }}); $('.accordion__faqs__content__ttl').each(function(){ var ttl=$(this); ttl.on('click', function(){ ttl.toggleClass('accordion__faqs__content__ttl--open'); ttl.next('.accordion__faqs__content__txt').slideToggle(); }); }); $(".review__btn").on("click", function(e){ e.preventDefault(); $("body").addClass("body--disableScrolled"); $("#modal").addClass("modal--open"); }); /*$("#modal").on("click", function(e){ if($(e.target).hasClass("modal")){ $("#modal").removeClass("modal--open"); $("body").removeClass("body--modal"); }});*/ $("#modal__close").on("click", function(){ $("#modal").removeClass("modal--open"); $("body").removeClass("body--disableScrolled"); }); $("a[href^='#']:not([href$='#'])").on('click', function(e){ e.preventDefault(); var target=$(this).attr('href'); var pos=0; var headerHeight=Math.ceil($(".header").height()); if(target!='#top__page'){ pos=$(target).offset().top - headerHeight; } $('html,body').stop().animate({ 'scrollTop': pos }, { 'duration': 500, 'easing': 'swing' }); return false; }); var url=''; var wpcf7Elm=document.querySelector('.wpcf7'); if(wpcf7Elm!=null){ wpcf7Elm.addEventListener('wpcf7invalid', function(event){ $("#cf7-error-modal").addClass("modal--open"); $('#preview-customize').removeClass("modal--open"); }, false); wpcf7Elm.addEventListener('wpcf7spam', function(event){ $("#cf7-spam-modal").addClass("modal--open"); $('#preview-customize').removeClass("modal--open"); }, false); wpcf7Elm.addEventListener('wpcf7mailsent', function(event){ $('#preview-customize').removeClass("modal--open"); location=SITE_URL+'/thank-you'; }, false); wpcf7Elm.addEventListener('wpcf7mailfailed', function(event){ $("#cf7-failed-modal").addClass("modal--open"); $('#preview-customize').removeClass("modal--open"); }, false); } $("#home-review-modal__close").on('click',function(){ $("#home-review-modal").removeClass("modal--open"); $("html").css("overflow","auto"); }); $("#arrival_date").datepicker({ minDate: new Date(), dateFormat:"dd MM yy", }); $("#departure_date").datepicker({ minDate: new Date(), dateFormat:"dd MM yy", }); $(".cf7-modal__close").on("click", function(){ $("#cf7-error-modal").removeClass("modal--open"); $("#cf7-spam-modal").removeClass("modal--open"); $("#cf7-sent-modal").removeClass("modal--open"); $("#cf7-failed-modal").removeClass("modal--open"); $("body").removeClass("body--disableScrolled"); location.reload(); }); $(".modal__cf7-button").on("click", function(){ $("#cf7-error-modal").removeClass("modal--open"); $("#cf7-spam-modal").removeClass("modal--open"); $("#cf7-sent-modal").removeClass("modal--open"); $("#cf7-failed-modal").removeClass("modal--open"); $("body").removeClass("body--disableScrolled"); }); $(document).ready(function(){ $('.sub-menu > li').on("hover", function(){ var sub_ul=$(this).children('.sub-menu'); var current_ul=$(this).parent('.sub-menu'); var parent_li=current_ul.parent('.menu-item'); var parent_ul=parent_li.parent('.sub-menu'); if($(window).width() > 750){ if(sub_ul.length > 0){ if(parent_ul.length >0){ highest_ul=Math.max(parent_ul.children('li').length,current_ul.children('li').length,sub_ul.children('li').length); new_height=highest_ul * $(this).outerHeight(); sub_ul.height(new_height); current_ul.height(new_height); parent_ul.height(new_height); }else{ highest_ul=Math.max(current_ul.children('li').length,sub_ul.children('li').length); new_height=highest_ul * $(this).outerHeight(); if(new_height!=0){ sub_ul.height(new_height); current_ul.height(new_height); }} }} }) $('.sub-menu > li').on("mouseenter", function(){ $(this).height('auto'); }) $('#header__menu--mobile a').on('click',function(e){ if(e.offsetX > (this.offsetWidth - 32)){ if($(this).next().length!=0){ $(this).next().stop(true,false).slideToggle("slow"); $(this).toggleClass('open'); e.preventDefault(); }} }); $('#mobile__menuicon--close').on('click',function(e){ e.preventDefault(); $('#header--mobile').removeClass('header--mobile--active'); }); $('#mobile__menuicon--open').on('click',function(e){ e.preventDefault(); $('#header--mobile').addClass('header--mobile--active'); }); $('#header__search--mobile, #header__search__menubar').on('click',function(e){ e.preventDefault(); $('#search--form').addClass('search--form--active'); $('header.header').addClass('header--searchform'); $('#header__menu').animate({opacity: "0"}); }); $('#search--closeform').on('click',function(e){ e.preventDefault(); $('#search--form').removeClass('search--form--active'); $('header.header').removeClass('header--searchform'); $('#header__menu').animate({opacity: "1"}); }); }); })(jQuery); $(document).ready(function(){ $('#detail-tour-review').on('submit',function(e){ e.preventDefault(); var url=$(this).data('url'); var form=$(this).serialize(); var post_id=$(this).data('post-id'); var user_id=$(this).data('user-id'); $.ajax({ url: url, method:"POST", data: { form:form, post_id:post_id, user_id:user_id, action:"add_review" }, success:function(response){ var result=jQuery.parseJSON(response); if(result.status=="success"){ $('#modal').removeClass("modal--open"); $('#response-message-modal').addClass('modal--open'); $("body").addClass("body--disableScrolled"); }else{ $('#modal').removeClass("modal--open"); $('#response-message-modal').addClass('modal--open'); $('#review-response-message').html(result.message); $("body").addClass("body--disableScrolled"); }} }); }) $('#home-review-form').on('submit',function(e){ e.preventDefault(); var url=$(this).data('url'); var form=$(this).serialize(); var post_id=$(this).data('post-id'); var user_id=$(this).data('user-id'); $.ajax({ url: url, method:"POST", data: { form:form, post_id:post_id, user_id:user_id, action:"add_review" }, success:function(response){ var result=jQuery.parseJSON(response); if(result.status=="success"){ $('#home-review-modal').removeClass("modal--open"); $('#response-message-modal').addClass('modal--open'); $("body").addClass("body--disableScrolled"); }else{ $('#home-review-modal').removeClass("modal--open"); $('#response-message-modal').addClass('modal--open'); $('#review-response-message').html(result.message); $("body").addClass("body--disableScrolled"); }} }); }); $('.rate-star').on('click',function(){ var onStar=parseInt($(this).data('value'), 10); var stars=$(this).parent().children('span.fa-star'); for (i=0; i < stars.length; i++){ $(stars[i]).removeClass('review-star-checked'); } for (i=0; i < onStar; i++){ $(stars[i]).addClass('review-star-checked'); } var input=$(this).parent().children('.star-voted'); input.val($(this).data('value')); }); $(".review-homepage__btn").on('click',function(e){ e.preventDefault(); $("#home-review-modal").addClass("modal--open"); $("html").css("overflow","hidden"); }); $(".review-homepage__content--readmore").on("click", function(e){ e.preventDefault(); var title=$(this).data('title'); var content=$(this).data('content'); var author=$(this).data('author'); var country=$(this).data('country'); $("#review-modal").addClass("modal--open"); $("html").css("overflow","hidden"); $(".review-homepage__modal").children('.review-homepage__modal--title').html(title); $(".review-homepage__modal").children('.review-homepage__modal--content').html(content); $(".review-homepage__modal").children('.review-homepage__modal--author').html('By '+author+' | From '+country); }); $(".review__desc__txt__readmore").on("click", function(e){ e.preventDefault(); var title=$(this).data('title'); var content=$(this).data('content'); var author=$(this).data('author'); var country=$(this).data('country'); $("#review-modal").addClass("modal--open"); $("html").css("overflow","hidden"); $(".review-homepage__modal").children('.review-homepage__modal--title').html(title); $(".review-homepage__modal").children('.review-homepage__modal--content').html(content); $(".review-homepage__modal").children('.review-homepage__modal--author').html('By '+author+' | From '+country); }); $("#review-modal__close").on("click", function(){ $("#review-modal").removeClass("modal--open"); $("body").removeClass("body--disableScrolled"); $("html").css("overflow","auto"); }); $("#home-review-modal__close").on('click',function(){ $("#home-review-modal").removeClass("modal--open"); $("body").removeClass("body--disableScrolled"); $("html").css("overflow","auto"); }); $('#response-message-modal__close').on('click',function(){ $("#response-message-modal").removeClass("modal--open"); $("html").css("overflow","auto"); location.reload(); }); }); (function($){ $('.preview-booking').on('click',function(){ var regex_email=/^([a-z\d!#$%&'*+\-\/=?^_`{|}~\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+(\.[a-z\d!#$%&'*+\-\/=?^_`{|}~\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+)*|"((([ \t]*\r\n)?[ \t]+)?([\x01-\x08\x0b\x0c\x0e-\x1f\x7f\x21\x23-\x5b\x5d-\x7e\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]|\\[\x01-\x09\x0b\x0c\x0d-\x7f\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))*(([ \t]*\r\n)?[ \t]+)?")@(([a-z\d\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]|[a-z\d\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF][a-z\d\-._~\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]*[a-z\d\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])\.)+([a-z\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]|[a-z\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF][a-z\d\-._~\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]*[a-z\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])\.?$/i; var regex_phone=/^\+?\d+$/; var error={}; if(!$('#departure_date').val()){ error.departure_date="You need to choose your departure date"; }else{ $('#departure_date').removeClass('invalid'); } if(!$('#your_name').val()){ error.your_name="You need to fill your first name"; }else{ $('#your_name').removeClass('invalid'); } if(!$('#your_last_name').val()){ error.your_last_name="You need to fill your last name"; }else{ $('#your_last_name').removeClass('invalid'); } if(!$('#your_country').val()){ error.your_country="You need to fill your country"; }else{ $('#your_country').removeClass('invalid'); } if(!$('#your_city').val()){ error.your_city="Your need to fill your city address"; }else{ $('#your_city').removeClass('invalid'); } if($("#your_robot").prop("checked")==false){ error.your_robot="You need to confirm you not a robot"; }else{ $('#robot-error').hide(); } if(!$('#your_email').val()){ error.your_email="You need to fill your email address"; }else{ if(regex_email.test($('#your_email').val())==false){ error.your_email="You need to fill correctly your email"; }else{ $('#your_email').removeClass('invalid'); }} if(!$('#your_phone').val()){ error.your_phone="You need to fill your phone"; }else{ if(regex_phone.test($('#your_phone').val())==false){ error.your_phone="You need to fill correctly your phone"; }else{ $('#your_phone').removeClass('invalid'); }} if((jQuery).isEmptyObject(error)==true){ var gender=$('#your_gender').val(); var first_name=$('#your_name').val(); var last_name=$('#your_last_name').val(); var fullname=gender+' '+first_name+' '+last_name; $('#tour_name').html($('#tour_name_detail').text()); $('#tour_code').html($('#tour_code_detail').text()); $('#tour_destination').html($('#tour_destination_detail').text()); $('#tour_departure').html($('#departure_date').val()); $('#tour_adults').html($('#people-adults').val()); $('#tour_childrens').html($('#notes_children_slot').val()); $('#tour_babys').html($('#notes_baby_slot').val()); $('#tour_fullname').html(fullname); $('#tour_country').html($('#your_country').val()); $('#tour_email').html($('#your_email').val()); $('#tour_phone').html($('#your_phone').val()); $('#tour_paymethod').html($('#your_find').val()); $('#tour_reason').html($('#your_reason').val()); $('#tour_price').html($('#total_price').text()); $('#tour_comment').html($('#your_comment').val()); $("#preview-booking").addClass("modal--open"); $("html").css("overflow","hidden"); }else{ (jQuery).each(error,function(key,value){ if(key=='your_robot'){ $('#robot-error').show(); }else{ $('#'+key).attr('placeholder',value); $('#'+key).addClass('invalid'); }}); }}) $('#people-adults').on('selectmenuchange',function(){ var product_id=$(this).data('product-id'); var adult_quantity=$(this).val(); var url=$(this).data('url'); $(this).attr('data-adult',adult_quantity); var children_quantity=$('#people-children').attr('data-children'); var baby_quantity=$('#people-baby').attr('data-baby'); $.ajax({ url: url, method:"POST", data: { product_id:product_id, adult:adult_quantity, children:children_quantity, baby:baby_quantity, action:"update_carts" }, success:function(response){ var result=jQuery.parseJSON(response); if(result.status=="success"){ $('#total_price').html(result.cart_total); $('#total_price_adult').html(result.total_price_adult); $('#total_price_children').html(result.total_price_children); $('#adult_quantity').html(result.adult_slot); $('#children_quantity').html(result.children_slot); $('#baby_quantity').html(result.baby_slot) $('#total_quantity').html(result.total_slot); $('#notes_total_slot').val(result.total_slot); $('#notes_adult_slot').val(result.adult_slot); $('#notes_children_slot').val(result.children_slot); $('#notes_baby_slot').val(result.baby_slot); }} }); }); $('#people-children').on('selectmenuchange',function(){ var product_id=$(this).data('product-id'); var children_quantity=$(this).val(); var url=$(this).data('url'); $(this).attr('data-children',children_quantity); var baby_quantity=$('#people-baby').attr('data-baby'); var adult_quantity=$('#people-adults').attr('data-adult'); $.ajax({ url: url, method:"POST", data: { product_id:product_id, adult:adult_quantity, children:children_quantity, baby:baby_quantity, action:"update_carts" }, success:function(response){ var result=jQuery.parseJSON(response); if(result.status=="success"){ $('#total_price').html(result.cart_total); $('#total_price_adult').html(result.total_price_adult); $('#total_price_children').html(result.total_price_children); $('#adult_quantity').html(result.adult_slot); $('#children_quantity').html(result.children_slot); $('#baby_quantity').html(result.baby_slot) $('#total_quantity').html(result.total_slot); $('#notes_total_slot').val(result.total_slot); $('#notes_adult_slot').val(result.adult_slot); $('#notes_children_slot').val(result.children_slot); $('#notes_baby_slot').val(result.baby_slot); }} }); }); $('#people-baby').on('selectmenuchange',function(){ var product_id=$(this).data('product-id'); var baby_quantity=$(this).val(); var url=$(this).data('url'); $(this).attr('data-baby',baby_quantity); var children_quantity=$('#people-children').attr('data-children'); var adult_quantity=$('#people-adults').attr('data-adult'); $.ajax({ url: url, method:"POST", data: { product_id:product_id, adult:adult_quantity, children:children_quantity, baby:baby_quantity, action:"update_carts" }, success:function(response){ var result=jQuery.parseJSON(response); if(result.status=="success"){ $('#total_price').html(result.cart_total); $('#total_price_adult').html(result.total_price_adult); $('#total_price_children').html(result.total_price_children); $('#adult_quantity').html(result.adult_slot); $('#children_quantity').html(result.children_slot); $('#baby_quantity').html(result.baby_slot) $('#total_quantity').html(result.total_slot); $('#notes_total_slot').val(result.total_slot); $('#notes_adult_slot').val(result.adult_slot); $('#notes_children_slot').val(result.children_slot); $('#notes_baby_slot').val(result.baby_slot); }} }); }); $('.preview-booking-submit').on('click',function(){ $('#booking-checkout').submit(); $('#preview-booking').removeClass("modal--open"); $('#loading-modal').addClass('modal--open'); }); $('.preview-booking-back-btn').on('click',function(e){ e.preventDefault(); $('#preview-booking').removeClass("modal--open"); $("html").css("overflow","auto"); }); $("#preview-booking__close").on("click", function(){ $('#preview-booking').removeClass("modal--open"); $("html").css("overflow","auto"); }); })(jQuery); $(document).ready(function(){ $('.contact-form-submit-btn').on('click',function(e){ e.preventDefault(); var regex_email=/^([a-z\d!#$%&'*+\-\/=?^_`{|}~\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+(\.[a-z\d!#$%&'*+\-\/=?^_`{|}~\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+)*|"((([ \t]*\r\n)?[ \t]+)?([\x01-\x08\x0b\x0c\x0e-\x1f\x7f\x21\x23-\x5b\x5d-\x7e\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]|\\[\x01-\x09\x0b\x0c\x0d-\x7f\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))*(([ \t]*\r\n)?[ \t]+)?")@(([a-z\d\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]|[a-z\d\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF][a-z\d\-._~\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]*[a-z\d\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])\.)+([a-z\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]|[a-z\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF][a-z\d\-._~\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]*[a-z\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])\.?$/i; var regex_phone=/^\+?\d+$/; var error={}; if(!$('#contact_name').val()){ error.contact_name="*You need to fill your given name"; }else{ $('#contact_name').removeClass('invalid'); } if(!$('#contact_family_name').val()){ error.contact_family_name="*You need to fill your given name"; }else{ $('#contact_family_name').removeClass('invalid'); } if(!$('#contact_nationality').val()){ error.contact_nationality="*You need to fill your nationality"; }else{ $('#contact_nationality').removeClass('invalid'); } if(!$('#contact_phone').val()){ error.contact_phone="*You need to fill your phone"; }else{ if(regex_phone.test($('#contact_phone').val())==false){ error.contact_phone="*You need to fill correctly your phone"; }else{ $('#contact_phone').removeClass('invalid'); }} if(!$('#contact_email').val()){ error.contact_email="*You need to fill your email address"; }else{ if(regex_email.test($('#contact_email').val())==false){ error.contact_email="*You need to fill correctly your email"; }else{ $('#contact_email').removeClass('invalid'); }} if(!$('#contact_title').val()){ error.contact_title="*You need to fill title message"; }else{ $('#contact_title').removeClass('invalid'); } if(!$('#contact_content').val()){ error.contact_content="*You need to fill content message"; }else{ $('#contact_content').removeClass('invalid') } if($("#contact_robot").prop("checked")==false){ error.contact_robot="*You need to confirm you not a robot"; }else{ $('#contact_robot_error').html(); } if((jQuery).isEmptyObject(error)==true){ $('.contact__input__form').submit(); $('#loading-modal').addClass('modal--open'); }else{ (jQuery).each(error,function(key,value){ if(key=='contact_robot'){ $('#contact_robot_error').html(value); }else{ $('#'+key).val(''); $('#'+key).attr('placeholder',value); $('#'+key).addClass('invalid'); }}); }}); }); !function(){document.addEventListener("DOMContentLoaded",function(){var a=document.getElementById("site-navigation");if(a){var b=a.querySelector("button");if(b){var c=a.querySelector("ul");if(!c)return void(b.style.display="none");b.setAttribute("aria-expanded","false"),c.setAttribute("aria-expanded","false"),c.classList.add("nav-menu"),b.addEventListener("click",function(){a.classList.toggle("toggled");var d=a.classList.contains("toggled")?"true":"false";b.setAttribute("aria-expanded",d),c.setAttribute("aria-expanded",d)});var d=document.getElementsByClassName("handheld-navigation");d.length>0&&[].forEach.call(d[0].querySelectorAll(".menu-item-has-children > a, .page_item_has_children > a"),function(a){var b=document.createElement("button");b.setAttribute("aria-expanded","false"),b.classList.add("dropdown-toggle");var c=document.createElement("span");c.classList.add("screen-reader-text"),c.appendChild(document.createTextNode(storefrontScreenReaderText.expand)),b.appendChild(c),a.parentNode.insertBefore(b,a.nextSibling),a.parentNode.classList.contains("current-menu-ancestor")&&(b.setAttribute("aria-expanded","true"),b.classList.add("toggled-on"),b.nextElementSibling.classList.add("toggled-on")),b.addEventListener("click",function(){for(b.classList.toggle("toggled-on");c.firstChild;)c.removeChild(c.firstChild);var a=b.classList.contains("toggled-on");b.setAttribute("aria-expanded",a),c.appendChild(document.createTextNode(a?storefrontScreenReaderText.collapse:storefrontScreenReaderText.expand)),b.nextElementSibling.classList.toggle("toggled-on")})}),[].forEach.call(document.querySelectorAll(".storefront-handheld-footer-bar .search > a"),function(a){a.addEventListener("click",function(b){a.parentElement.classList.toggle("active"),b.preventDefault()})});var e=document.getElementsByClassName("storefront-handheld-footer-bar"),f=document.forms,g=function(a){return function(){a?document.body.classList.add("sf-input-focused"):document.body.classList.remove("sf-input-focused")}};if(e.length&&f.length)for(var h=0;h a, .site-header .page_item > a, .site-header-cart a"),function(a){var b=a.parentNode;a.addEventListener("focus",function(){b.classList.add("focus")}),a.addEventListener("blur",function(){b.classList.remove("focus")})}),("ontouchstart"in window||navigator.maxTouchPoints)&&window.innerWidth>767&&[].forEach.call(document.querySelectorAll(".site-header ul ul, .site-header-cart .widget_shopping_cart"),function(a){a.classList.add("sub-menu--is-touch-device")})}}})}(); !function(){var a=navigator.userAgent.toLowerCase().indexOf("webkit")>-1,b=navigator.userAgent.toLowerCase().indexOf("opera")>-1,c=navigator.userAgent.toLowerCase().indexOf("msie")>-1;(a||b||c)&&document.getElementById&&window.addEventListener&&window.addEventListener("hashchange",function(){var a=document.getElementById(location.hash.substring(1));a&&(/^(?:a|select|input|button|textarea)$/i.test(a.tagName)||(a.tabIndex=-1),a.focus())},!1)}(); var addComment={moveForm:function(a,b,c,d){var e,f,g,h,i=this,j=i.I(a),k=i.I(c),l=i.I("cancel-comment-reply-link"),m=i.I("comment_parent"),n=i.I("comment_post_ID"),o=k.getElementsByTagName("form")[0];if(j&&k&&l&&m&&o){i.respondId=c,d=d||!1,i.I("wp-temp-form-div")||(e=document.createElement("div"),e.id="wp-temp-form-div",e.style.display="none",k.parentNode.insertBefore(e,k)),j.parentNode.insertBefore(k,j.nextSibling),n&&d&&(n.value=d),m.value=b,l.style.display="",l.onclick=function(){var a=addComment,b=a.I("wp-temp-form-div"),c=a.I(a.respondId);if(b&&c)return a.I("comment_parent").value="0",b.parentNode.insertBefore(c,b),b.parentNode.removeChild(b),this.style.display="none",this.onclick=null,!1};try{for(var p=0;p
    '; for(var i in heateorSssMoreSharingServices){ var tempTitle=heateorSssCapitaliseFirstLetter(heateorSssMoreSharingServices[i].title.replace(/[_. ]/g, "")); heateorSssMoreSharingServicesHtml +='
  • ' + heateorSssMoreSharingServices[i].title + '
  • '; } heateorSssMoreSharingServicesHtml +=concate; var mainDiv=document.createElement('div'); mainDiv.innerHTML=heateorSssMoreSharingServicesHtml; mainDiv.setAttribute('id', 'heateor_sss_sharing_more_providers'); var bgDiv=document.createElement('div'); bgDiv.setAttribute('id', 'heateor_sss_popup_bg'); jQuery('body').append(mainDiv).append(bgDiv); document.getElementById('heateor_sss_popup_bg').onclick=document.getElementById('heateor_sss_sharing_popup_close').onclick=function(){ mainDiv.parentNode.removeChild(mainDiv); bgDiv.parentNode.removeChild(bgDiv); }} if(heateorSssHorizontalSharingCountEnable||heateorSssVerticalSharingCountEnable){ heateorSssLoadEvent( function(){ heateorSssCallAjax(function(){ heateorSssGetSharingCounts(); }); } ); } function heateorSssFilterSharing(val){ jQuery('ul.mini li a').each(function(){ if(jQuery(this).text().toLowerCase().indexOf(val.toLowerCase())!=-1){ jQuery(this).parent().css('display', 'block'); }else{ jQuery(this).parent().css('display', 'none'); }}); }; var heateorSssFacebookTargetUrls=[]; function heateorSssGetSharingCounts(){ var targetUrls=[]; jQuery('.heateor_sss_sharing_container').each(function(){ if(typeof jQuery(this).attr('heateor-sss-no-counts')=='undefined'){ var currentTargetUrl=jQuery(this).attr('heateor-sss-data-href'); if(currentTargetUrl!=null&&jQuery.inArray(currentTargetUrl, heateorSssUrlCountFetched)==-1){ targetUrls.push(currentTargetUrl); heateorSssUrlCountFetched.push(currentTargetUrl); }} }); if(targetUrls.length==0){ return; } jQuery.ajax({ type: 'GET', dataType: 'json', url: heateorSssSharingAjaxUrl, data: { action: 'heateor_sss_sharing_count', urls: targetUrls, }, success: function(data, textStatus, XMLHttpRequest){ if(data.status==1){ if(data.facebook){ heateorSssFacebookTargetUrls=data.facebook_urls; } for(var i in data.message){ var sharingContainers=jQuery("div[heateor-sss-data-href='"+i+"']"); jQuery(sharingContainers).each(function(){ var totalCount=0; for(var j in data.message[i]){ var sharingCount=parseInt(data.message[i][j])||0; var targetElement=jQuery(this).find('.heateor_sss_'+j+'_count'); if(jQuery(targetElement).attr('sss_st_count')){ sharingCount=parseInt(sharingCount) + parseInt(jQuery(targetElement).attr('sss_st_count')); } totalCount +=parseInt(sharingCount); if(sharingCount < 1){ continue; } jQuery(targetElement).html(heateorSssCalculateApproxCount(sharingCount)).css({'visibility': 'visible', 'display': 'block'}); if(( typeof heateorSssReduceHorizontalSvgWidth!='undefined'&&jQuery(this).hasClass('heateor_sss_horizontal_sharing'))||(typeof heateorSssReduceVerticalSvgWidth!='undefined'&&jQuery(this).hasClass('heateor_sss_vertical_sharing'))){ jQuery(targetElement).parents('li').find('.heateorSssSharingSvg').css('float', 'left'); } if(( typeof heateorSssReduceHorizontalSvgHeight!='undefined'&&jQuery(this).hasClass('heateor_sss_horizontal_sharing'))||(typeof heateorSssReduceVerticalSvgHeight!='undefined'&&jQuery(this).hasClass('heateor_sss_vertical_sharing'))){ jQuery(targetElement).parents('li').find('.heateorSssSharingSvg').css('marginTop', '0'); }} var totalCountContainer=jQuery(this).find('.heateorSssTCBackground'), totalShares=heateorSssCalculateApproxCount(totalCount); jQuery(totalCountContainer).each(function(){ var containerHeight=jQuery(this).css('height'); jQuery(this).html('
    ' + totalShares + '
    ' + (totalCount==0||totalCount > 1 ? heateorSssSharesText:heateorSssShareText) + '
    ').css('visibility', 'visible'); }); }); } if(heateorSssFacebookTargetUrls.length!=0){ heateorSssFetchFacebookShares(heateorSssFacebookTargetUrls); }} }}); } function heateorSssFetchFacebookShares(targetUrls){ var loopCounter=0; for(var i in targetUrls){ for(var j in targetUrls[i]){ loopCounter++; heateorSssFBShareJSONCall(targetUrls[i][j], loopCounter, targetUrls[0].length*targetUrls.length, targetUrls[0][j]); }} } function heateorSssFBShareJSONCall(targetUrl, loopCounter, targetUrlsLength, dataHref){ jQuery.getJSON('//graph.facebook.com/?id=' + targetUrl, function(data){ if(data.share&&data.share.share_count >=0){ var sharingContainers=jQuery("div[heateor-sss-data-href='"+dataHref+"']"); jQuery(sharingContainers).each(function(){ var targetElement=jQuery(this).find('.heateor_sss_facebook_count'); var facebookBackground=jQuery(this).find('i.heateorSssFacebookBackground'); var sharingCount=parseInt(data.share.share_count); if(jQuery(targetElement).attr('sss_st_count')!==undefined){ sharingCount +=parseInt(jQuery(targetElement).attr('sss_st_count')); } if(sharingCount > 0){ if(typeof jQuery(facebookBackground).attr('heateor-sss-fb-shares')=='undefined'){ jQuery(targetElement).html(heateorSssCalculateApproxCount(sharingCount)).css({'visibility': 'visible', 'display': 'block'}); jQuery(facebookBackground).attr('heateor-sss-fb-shares', sharingCount); }else if(typeof jQuery(facebookBackground).attr('heateor-sss-fb-shares')!='undefined'){ var tempShareCount=parseInt(jQuery(facebookBackground).attr('heateor-sss-fb-shares')); jQuery(facebookBackground).attr('heateor-sss-fb-shares', sharingCount + tempShareCount); jQuery(targetElement).html(heateorSssCalculateApproxCount(sharingCount + tempShareCount)); } if(( typeof heateorSssReduceHorizontalSvgWidth!='undefined'&&jQuery(this).hasClass('heateor_sss_horizontal_sharing'))||(typeof heateorSssReduceVerticalSvgWidth!='undefined'&&jQuery(this).hasClass('heateor_sss_vertical_sharing'))){ jQuery(targetElement).parents('li').find('.heateorSssSharingSvg').css('float', 'left'); } if(( typeof heateorSssReduceHorizontalSvgHeight!='undefined'&&jQuery(this).hasClass('heateor_sss_horizontal_sharing'))||(typeof heateorSssReduceVerticalSvgHeight!='undefined'&&jQuery(this).hasClass('heateor_sss_vertical_sharing'))){ jQuery(targetElement).parents('li').find('.heateorSssSharingSvg').css('marginTop', '0'); } var totalCountContainer=jQuery(this).find('.heateorSssTCBackground'); jQuery(totalCountContainer).each(function(){ var totalShareCountElem=jQuery(this).find('.heateorSssTotalShareCount'); var totalShareCount=jQuery(totalShareCountElem).text(); var newTotalCount=heateorSssCalculateActualCount(totalShareCount) + sharingCount; jQuery(totalShareCountElem).text(heateorSssCalculateApproxCount(newTotalCount)); jQuery(this).find('.heateorSssTotalShareText').text(newTotalCount==0||newTotalCount > 1 ? heateorSssSharesText:heateorSssShareText); }); }}); } if(loopCounter==targetUrlsLength){ setTimeout(function(){ var facebookShares={}; for(var i in heateorSssFacebookTargetUrls[0]){ var sharingContainers=jQuery("div[heateor-sss-data-href='"+heateorSssFacebookTargetUrls[0][i]+"']"); jQuery(sharingContainers).each(function(){ var facebookCountElement=jQuery(this).find('.heateor_sss_facebook_count'); var facebookCountElementBg=jQuery(this).find('i.heateorSssFacebookBackground'); var shareCountString=typeof jQuery(facebookCountElementBg).attr('heateor-sss-fb-shares')!='undefined' ? jQuery(facebookCountElementBg).attr('heateor-sss-fb-shares').trim():''; if(shareCountString!=''){ var shareCount=parseInt(heateorSssCalculateActualCount(shareCountString)); if(jQuery(facebookCountElement).attr('sss_st_count')!==undefined){ var startingCount=parseInt(jQuery(facebookCountElement).attr('sss_st_count').trim()); shareCount=Math.abs(shareCount - startingCount); } facebookShares[heateorSssFacebookTargetUrls[0][i]]=shareCount; return; }}); } if(!jQuery.isEmptyObject(facebookShares)){ heateorSssSaveFacebookShares(facebookShares); }}, 1000); }}); } function heateorSssSaveFacebookShares(facebookShares){ jQuery.ajax({ type: 'GET', dataType: 'json', url: heateorSssSharingAjaxUrl, data: { action: 'heateor_sss_save_facebook_shares', share_counts: facebookShares, }, success: function(data, textStatus, XMLHttpRequest){}}); } function heateorSssCalculateApproxCount(sharingCount){ if(sharingCount > 999&&sharingCount < 10000){ sharingCount=(Math.round(sharingCount/100))/10 + 'K'; }else if(sharingCount > 9999&&sharingCount < 100000){ sharingCount=(Math.round(sharingCount/100))/10 + 'K'; }else if(sharingCount > 99999&&sharingCount < 1000000){ sharingCount=(Math.round(sharingCount/100))/10 + 'K'; }else if(sharingCount > 999999){ sharingCount=(Math.round(sharingCount/100000))/10 + 'M'; } return sharingCount; } function heateorSssCalculateActualCount(sharingCount){ if(sharingCount.indexOf('K') > 0){ sharingCount=sharingCount.replace('K', '') * 1000; }else if(sharingCount.indexOf('M') > 0){ sharingCount=sharingCount.replace('M', '') * 1000000; } return parseInt(sharingCount); } function heateorSssCapitaliseFirstLetter(e){ return e.charAt(0).toUpperCase() + e.slice(1) } jQuery(function(){ var classes=['heateor_sss_vertical_sharing', 'heateor_sss_vertical_counter']; for(var i=0; i < classes.length; i++){ if(jQuery('.' + classes[i]).length){ jQuery('.' + classes[i]).each(function(){ var verticalSharingHtml=jQuery(this).html(); if(jQuery(this).attr('style').indexOf('right') >=0){ var removeClass='heateorSssPushIn', margin='Right', alignment='right', addClass='heateorSssPullOut'; }else{ var removeClass='heateorSssPullOut', margin='Left', alignment='left', addClass='heateorSssPushIn'; } jQuery(this).html(verticalSharingHtml + '
    '); }); }} if(heateorSssMobileStickySharingEnabled==1){ if(jQuery('div.heateor_sss_vertical_sharing').length){ jQuery(document.body).append(""); }} var heateorSssClipboard=new Clipboard('.heateorSssCopyLinkBackground, .heateorSssCopyLinkShare, .heateorSssCopyLinkSvg', { text: function(trigger){ if(jQuery(trigger).hasClass('heateorSssCopyLinkShare')){ var element=trigger.parentElement.parentElement.parentElement.parentElement; var url=jQuery(element).attr("data-href")||""; }else if(jQuery(trigger).hasClass('heateorSssCopyLinkSvg')){ var element=trigger.parentElement.parentElement.parentElement.parentElement; var url=jQuery(element).attr("heateor-sss-data-href")||""; if(!url){ var element=trigger.parentElement.parentElement.parentElement.parentElement.parentElement.parentElement; var url=jQuery(element).attr("data-href")||""; }} return url; }}); heateorSssClipboard.on('success', function(e){ alert(heateorSssCopyLinkMessage); }); }); function heateorSssHideSharing(elem, removeClass, addClass, margin, alignment){ var animation={}, counter=jQuery(elem).parent().hasClass('heateor_sss_vertical_counter'), offset=parseInt(jQuery(elem).parent().css('width')) + 10 - (counter ? 16:0); var ssOffset=jQuery(elem).parent().attr('ss-offset'); if(ssOffset){ var savedOffset=parseInt(ssOffset); }else{ var savedOffset=(counter ? heateorSssCounterOffset:heateorSssSharingOffset); } if(jQuery(elem).attr('title')=='Hide'){ animation[alignment]="-=" + (offset + savedOffset); jQuery(elem).parent().animate(animation, 400, function(){ jQuery(elem).removeClass(removeClass).addClass(addClass).attr('title', 'Share'); if(counter){ var cssFloat=alignment=='left' ? 'right':'left'; jQuery(elem).css('float', cssFloat); }else{ jQuery(elem).css('margin' + margin, offset + 'px') }}); }else{ animation[alignment]="+=" + (offset + savedOffset); jQuery(elem).parent().animate(animation, 400, function(){ jQuery(elem).removeClass(addClass).addClass(removeClass).attr('title', 'Hide'); if(counter){ jQuery(elem).css('float', alignment); }else{ jQuery(elem).css('margin' + margin, '0px'); }}); }} !function(t){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var e;e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this,e.Clipboard=t()}}(function(){var t,e,n;return function t(e,n,o){function i(a,c){if(!n[a]){if(!e[a]){var l="function"==typeof require&&require;if(!c&&l)return l(a,!0);if(r)return r(a,!0);var s=new Error("Cannot find module '"+a+"'");throw s.code="MODULE_NOT_FOUND",s}var u=n[a]={exports:{}};e[a][0].call(u.exports,function(t){var n=e[a][1][t];return i(n||t)},u,u.exports,t,e,n,o)}return n[a].exports}for(var r="function"==typeof require&&require,a=0;a0&&void 0!==arguments[0]?arguments[0]:{};this.action=e.action,this.container=e.container,this.emitter=e.emitter,this.target=e.target,this.text=e.text,this.trigger=e.trigger,this.selectedText=""}},{key:"initSelection",value:function t(){this.text?this.selectFake():this.target&&this.selectTarget()}},{key:"selectFake",value:function t(){var e=this,n="rtl"==document.documentElement.getAttribute("dir");this.removeFake(),this.fakeHandlerCallback=function(){return e.removeFake()},this.fakeHandler=this.container.addEventListener("click",this.fakeHandlerCallback)||!0,this.fakeElem=document.createElement("textarea"),this.fakeElem.style.fontSize="12pt",this.fakeElem.style.border="0",this.fakeElem.style.padding="0",this.fakeElem.style.margin="0",this.fakeElem.style.position="absolute",this.fakeElem.style[n?"right":"left"]="-9999px";var o=window.pageYOffset||document.documentElement.scrollTop;this.fakeElem.style.top=o+"px",this.fakeElem.setAttribute("readonly",""),this.fakeElem.value=this.text,this.container.appendChild(this.fakeElem),this.selectedText=(0,i.default)(this.fakeElem),this.copyText()}},{key:"removeFake",value:function t(){this.fakeHandler&&(this.container.removeEventListener("click",this.fakeHandlerCallback),this.fakeHandler=null,this.fakeHandlerCallback=null),this.fakeElem&&(this.container.removeChild(this.fakeElem),this.fakeElem=null)}},{key:"selectTarget",value:function t(){this.selectedText=(0,i.default)(this.target),this.copyText()}},{key:"copyText",value:function t(){var e=void 0;try{e=document.execCommand (this.action)}catch(t){e=!1}this.handleResult(e)}},{key:"handleResult",value:function t(e){this.emitter.emit(e?"success":"error",{action:this.action,text:this.selectedText,trigger:this.trigger,clearSelection:this.clearSelection.bind(this)})}},{key:"clearSelection",value:function t(){this.trigger&&this.trigger.focus(),window.getSelection().removeAllRanges()}},{key:"destroy",value:function t(){this.removeFake()}},{key:"action",set:function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"copy";if(this._action=e,"copy"!==this._action&&"cut"!==this._action)throw new Error('Invalid "action" value, use either "copy" or "cut"')},get:function t(){return this._action}},{key:"target",set:function t(e){if(void 0!==e){if(!e||"object"!==(void 0===e?"undefined":r(e))||1!==e.nodeType)throw new Error('Invalid "target" value, use a valid Element');if("copy"===this.action&&e.hasAttribute("disabled"))throw new Error('Invalid "target" attribute. Please use "readonly" instead of "disabled" attribute');if("cut"===this.action&&(e.hasAttribute("readonly")||e.hasAttribute("disabled")))throw new Error('Invalid "target" attribute. You can\'t cut text from elements with "readonly" or "disabled" attributes');this._target=e}},get:function t(){return this._target}}]),t}();t.exports=c})},{select:5}],8:[function(e,n,o){!function(i,r){if("function"==typeof t&&t.amd)t(["module","./clipboard-action","tiny-emitter","good-listener"],r);else if(void 0!==o)r(n,e("./clipboard-action"),e("tiny-emitter"),e("good-listener"));else{var a={exports:{}};r(a,i.clipboardAction,i.tinyEmitter,i.goodListener),i.clipboard=a.exports}}(this,function(t,e,n,o){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function a(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function c(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function l(t,e){var n="data-clipboard-"+t;if(e.hasAttribute(n))return e.getAttribute(n)}var s=i(e),u=i(n),f=i(o),d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},h=function(){function t(t,e){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:{};this.action="function"==typeof e.action?e.action:this.defaultAction,this.target="function"==typeof e.target?e.target:this.defaultTarget,this.text="function"==typeof e.text?e.text:this.defaultText,this.container="object"===d(e.container)?e.container:document.body}},{key:"listenClick",value:function t(e){var n=this;this.listener=(0,f.default)(e,"click",function(t){return n.onClick(t)})}},{key:"onClick",value:function t(e){var n=e.delegateTarget||e.currentTarget;this.clipboardAction&&(this.clipboardAction=null),this.clipboardAction=new s.default({action:this.action(n),target:this.target(n),text:this.text(n),container:this.container,trigger:n,emitter:this})}},{key:"defaultAction",value:function t(e){return l("action",e)}},{key:"defaultTarget",value:function t(e){var n=l("target",e);if(n)return document.querySelector(n)}},{key:"defaultText",value:function t(e){return l("text",e)}},{key:"destroy",value:function t(){this.listener.destroy(),this.clipboardAction&&(this.clipboardAction.destroy(),this.clipboardAction=null)}}],[{key:"isSupported",value:function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:["copy","cut"],n="string"==typeof e?[e]:e,o=!!document.queryCommandSupported;return n.forEach(function(t){o=o&&!!document.queryCommandSupported(t)}),o}}]),e}(u.default);t.exports=p})},{"./clipboard-action":7,"good-listener":4,"tiny-emitter":6}]},{},[8])(8)}); !function(){document.body.classList.contains("woocommerce-cart")||document.body.classList.contains("woocommerce-checkout")||window.innerWidth<768||!document.getElementById("site-header-cart")||window.addEventListener("load",function(){document.querySelector(".site-header-cart").addEventListener("mouseover",function(){var a=window.outerHeight,b=this.querySelector(".widget_shopping_cart_content").getBoundingClientRect().bottom+this.offsetHeight,c=this.querySelector(".cart_list");b>a&&(c.style.maxHeight="15em",c.style.overflowY="auto")})})}(); !function(a,b){"use strict";function c(){if(!e){e=!0;var a,c,d,f,g=-1!==navigator.appVersion.indexOf("MSIE 10"),h=!!navigator.userAgent.match(/Trident.*rv:11\./),i=b.querySelectorAll("iframe.wp-embedded-content");for(c=0;c1e3)g=1e3;else if(~~g<200)g=200;f.height=g}if("link"===d.message)if(h=b.createElement("a"),i=b.createElement("a"),h.href=f.getAttribute("src"),i.href=d.value,i.host===h.host)if(b.activeElement===f)a.top.location.href=d.value}else;}},d)a.addEventListener("message",a.wp.receiveEmbedMessage,!1),b.addEventListener("DOMContentLoaded",c,!1),a.addEventListener("load",c,!1)}(window,document);